package com.growthserver.mapper;

import com.growthserver.entity.IntegralBudgetEntity;
import com.growthserver.entity.TTaskAssignEntity;
import com.growthserver.entity.UserInfoEntity;
import com.growthserver.excelFileEntity.IntegralBudgetExclEntity;
import com.growthserver.param.GrowthInfo;
import com.growthserver.param.GrowthParam;
import com.growthserver.param.IntegralBudgetParam;
import com.growthserver.param.IntegralInfo;
import com.growthserver.vo.IntegralBudgetVo;
import com.growthserver.vo.TTaskAssignVo;
import org.apache.ibatis.annotations.Param;

import java.util.HashMap;
import java.util.List;

public interface GrowthCenterMapper {
    /**
     * 批量发放积分明细查询
     */
    List<TTaskAssignEntity> detailQuery(GrowthParam growthParam);

    /**
     * 查看
     * @param taskId
     * @return
     */
    List<HashMap<String,String>> queryMemberIds(@Param("taskId")String taskId);

    /**
     * 删除
     * @param taskId
     */
    void deleteById(@Param("taskId") String taskId);

    /**
     * 获取用户积分明细
     * @param growthParam
     */
    List<UserInfoEntity> getUserInfo(GrowthParam growthParam);
    /**
     * 任务类型模具
     * @param growthParam
     */
    List<String> taskTypeEnum(GrowthParam growthParam);
    List<IntegralInfo> integralDetails(@Param("userId") String userId,
                                       @Param("deductionType")String deductionType);

    List<GrowthInfo> growthDetailList(@Param("userId") String userId);

    int willExpIntegral(@Param("userId") String userId,
                                 @Param("expDays")int expDays);
    /**
     * 批量发放,单独发送
     */
    void batchOrSimpleSend(TTaskAssignVo tTaskAssignVo);

    /**
     * 发放积分日志表
     */
    /**
     * 积分数据等级存储表
     */
    Object integralGrowthLvl(@Param("userId")String userId,@Param("memberType") String memberType);

    /**
     * 数据添加关联表
     */
    void insetUserIntegral(@Param("userIds") List<String> userIds ,
                           @Param("taskId") String taskId,
                           @Param("integralTimeRange")String integralTimeRange,
                           @Param("creator")String creator,
                           @Param("createdName")String createdName);


    /**
     * 查询 申请审批积分任务数据
     */
    List<IntegralBudgetEntity>  queryIntegralBudget(IntegralBudgetParam integralBudgetParams);

    /**
     * 申请审批积分创建
     * @param integralBudgetVo
     */
    void  integralBudgetCreate(IntegralBudgetVo integralBudgetVo);

    /**
     * 积分预算审核
     * @param integralBudgetEntity
     */
    void  integralBudgetAudit(IntegralBudgetEntity integralBudgetEntity);

    /**
     * 积分创建excel导入
     * @param integralBudgetExclEntities
     */
    void  integralBudgetExcel(@Param("integralBudgetExclEntities") List<IntegralBudgetExclEntity> integralBudgetExclEntities);

    /**
     *
     * @param
     */
    List<String>  selectIntegralBudgetNum();
}
